home *** CD-ROM | disk | FTP | other *** search
- ` ------------------------------------------------------------------------
- ` Full Screen Distorter DarkForge Snippet (17/8/2000)
- ` ------------------------------------------------------------------------
- ` Sinewave distorts a full-screen (640x480) image - the fastest yet in DB!
-
- sync rate 0
- sync on
- hide mouse
-
- load bitmap "anhk_inside.bmp",1
- create bitmap 2,640,480
-
- set current bitmap 1
- for i=1 to 480
- get image i,0,i-1,640,i
- next i
-
- set text opaque
- ink rgb(255,255,255),0
-
- ` Change these values to alter the distortion effect
- ` Uncomment a step line for a different style
-
- ` Small waveform, slow, smooth
- `step=2 : sx=0 : speed=2
-
- ` Typical demo effect speed/wave :)
- step=3 : sx=0 : speed=3
-
- ` Lots of fast ripples!
- `step=8 : sx=0 : speed=4
-
- ` One large fast ripple
- `step=2 : sx=0 : speed=16
-
- do
-
- set current bitmap 2
-
- ` The CLS is optional, if you comment it out you get a quite cool
- ` pixel-drag effect on the sides of the screen - try it and see!
-
- cls 0
-
- for i=1 to 480
- paste image i,sin(sx+i*step)*25,i
- next i
-
- inc sx,speed
-
- ` Uncomment to show fps
- ` text 0,0,str$(screen fps())
-
- set current bitmap 0
- copy bitmap 2,0
-
- sync
-
- loop
-
-